<fieldset>
    <legend>条件搜索</legend>
    <form action="{:url('index')}" autocomplete="off" class="layui-form layui-form-pane form-search" method="get" onsubmit="return false">
        <div class="layui-form-item layui-inline">
            <label class="layui-form-label">模板编号</label>
            <label class="layui-input-inline">
                <input class="layui-input" name="code" placeholder="请输入模板编号" value="{$get.code|default=''}">
            </label>
        </div>

        <div class="layui-form-item layui-inline">
            <label class="layui-form-label">模板名称</label>
            <label class="layui-input-inline">
                <input class="layui-input" name="name" placeholder="请输入模板名称" value="{$get.name|default=''}">
            </label>
        </div>

        <div class="layui-form-item layui-inline">
            <label class="layui-form-label">使用状态</label>
            <label class="layui-input-inline">
                <select class="layui-select" name="status">
                    <option value=''>-- 全部状态 --</option>
                    {foreach ['已禁用的模板','已激活的模板'] as $k=>$v}
                    {if input('status','-') eq $k.''}
                    <option selected value="{$k}">{$v}</option>
                    {else}
                    <option value="{$k}">{$v}</option>
                    {/if}{/foreach}
                </select>
            </label>
        </div>

        <div class="layui-form-item layui-inline">
            <label class="layui-form-label">添加时间</label>
            <label class="layui-input-inline">
                <input class="layui-input" data-date-range name="create_at" placeholder="请选择添加时间" value="{$get.create_at|default=''}">
            </label>
        </div>

        <div class="layui-form-item layui-inline">
            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
        </div>
    </form>
    <script>form.render()</script>
</fieldset>

